<!--
 * @Author: Zhouxin 2890091630@qq.com
 * @Date: 2024-08-27 00:34:02
 * @LastEditors: Zhouxin 2890091630@qq.com
 * @LastEditTime: 2024-08-27 00:41:13
 * @FilePath: \2024-8-22(26)-day13\练习下 课前小案例 (数组切割+拼接)的那个案例.html
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>练习下 课前小案例 (数组切割+拼接)的那个案例</title>
</head>
<body>
    <script>
        function Add(arrA , arrB) {
            var maxLen = 7;
            var arrAlen = arrA.length;
            return arrA.concat(arrB.slice(0, maxLen - arrAlen));
        }

        console.log(Add([1,2,3,4,5],[6,7,8,9,10]));
    </script>
</body>
</html>